#ifndef _DEVICE_ICE_
#define _DEVICE_ICE_
#include "PhoneType.ice"
module databean {
const int WEIXINBIT = 1;
const int EMAILBIT = 2;
const int SMSBIT = 4;

enum ACTIONTYPE{EMAIl, XINGEID, ALLOWDISTURB, SMSPHONE, MODE, INTERVAL, ALERTON, ALERTMETHOD};
enum REMOTEACTIONTYPE{RSMSPHONE, RRMODE, REMAIL};
enum WORKMODE {AUTO, MANNUAL};//0（自动，正常模式）;1（手动模式）
enum INTEVAL {HALFMINUTE, TENMINUTES, ONEHOUR};//0:30s;1:10min;2:1 hour
sequence<databean::PhoneType> phones;
    class Device {
        ["java:getset"] string email;/*邮件*/
        ["java:getset"] string xingeId;/*信鸽ID*/
        
        ["java:getset"] bool allowDisturb;/*是否勿扰模式*/
        /*监控手机号码的添加提供单独的接口（因为要验证密码），所以不提供ACTIONTYPE枚举变量*/
        ["java:getset"] phones moniPhone;/*监控手机号码（数组）*/
        ["java:getset"] string smsPhone;/*短信报警的号码*/

        ["java:getset"] int mode;/*工作模式,使用WORKMODE枚举值  ;*/
        ["java:getset"] int interval;/*上传间隔,使用INTEVAL枚举值  */
        ["java:getset"] bool alertOn;/*报警提示*/
        ["java:getset"] int alertMethod;/*电量报警方式,用常量WEIXINBIT、EMAILBIT、SMSBIT位或计算取得*/
        /*电量在心跳的接口上传，所以不提供ACTIONTYPE枚举变量*/
        ["java:getset"] int power;/*电量，最大值100，表示电量百分比*/
        ["java:getset"] string weixinId;/*微信openid*/
        ["java:getset"] bool isLost;/*是否被挂失*/    
    };
};
#endif